home *** CD-ROM | disk | FTP | other *** search
/ Experimental BBS Explossion 3 / Experimental BBS Explossion III.iso / c / pcw.zip / HIDESHOW.C < prev    next >
Text File  |  1990-01-16  |  2KB  |  50 lines

  1. /***********************************************************/
  2. /* File Id.                  Wshow.C                       */
  3. /* Author.                   Stan Milam.                   */
  4. /* Date Written.             11/14/88.                     */
  5. /* Date Last Modified.                                     */
  6. /*                                                         */
  7. /*            (c) Copyright 1989-90 by Stan Milam          */
  8. /*                                                         */
  9. /* Comments: This module will show a window that has been  */
  10. /* hidden with whide().  It will first copy the contents of*/
  11. /* the screen where this window will be in case the screen */
  12. /* has changed since the window was hidden.  Then the win- */
  13. /* dow will be restored from the *wsave buffer.            */
  14. /***********************************************************/
  15.  
  16. #include "pcw.i"
  17. #include "pcwproto.h"
  18.  
  19. #define NULL 0
  20.  
  21. static int mx_rows, mx_cols;
  22.  
  23. int wshow(WNDPTR *wnd)  {
  24.  
  25.    if (!wnd) return(0);
  26.    if (!chk_video_state(&mx_rows,&mx_cols)) return(0);
  27.    re_order(wnd, SHOW);
  28.    return(1);
  29. }
  30.  
  31. /***********************************************************/
  32. /* File Id.                  Whide.C                       */
  33. /* Author.                   Stan Milam.                   */
  34. /* Date Written.             11/14/88.                     */
  35. /* Date Last Modified.                                     */
  36. /*                                                         */
  37. /* Comments: This function will hide a window.  First it   */
  38. /* will save the current contents of the window in *wsave  */
  39. /* then restore the original screen block from *wbuffer.   */
  40. /***********************************************************/
  41.  
  42. int whide(WNDPTR *wnd) {
  43.  
  44.     if (!wnd) return(0);
  45.     if (!chk_video_state(&mx_rows,&mx_cols)) return(0);
  46.  
  47.     re_order(wnd, HIDE);
  48.     return(1);
  49. }
  50.